export const rules = {
  ownerOrgObjID: {
    required: true,
    message: '请选择运维公司',
    trigger: 'change',
  },
}

export interface SellForm {
  assetObjIDs: string[]
  ownerOrgObjID: string
  remark: string
}

export function useInitForm(): { formData: Ref<SellForm>, initForm: () => void } {
  const getData = () => ({
    assetObjIDs: [],
    ownerOrgObjID: '',
    remark: '',
  })
  const formData = ref<SellForm>(getData())

  const initForm = () => {
    formData.value = getData()
  }

  return { formData, initForm }
}
